home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Club 2000 October / Software of the Month - Ultimate Collection Shareware 277.iso / pc / PROGRAMS / UTILITY / WINLINUX / DATA1.CAB / programs_-_include / LINUX / X25.H < prev    next >
C/C++ Source or Header  |  1999-09-17  |  2KB  |  94 lines

  1. /*
  2.  * These are the public elements of the Linux kernel X.25 implementation.
  3.  */
  4.  
  5. #ifndef    X25_KERNEL_H
  6. #define    X25_KERNEL_H
  7.  
  8. #define    SIOCX25GSUBSCRIP    (SIOCPROTOPRIVATE + 0)
  9. #define    SIOCX25SSUBSCRIP    (SIOCPROTOPRIVATE + 1)
  10. #define    SIOCX25GFACILITIES    (SIOCPROTOPRIVATE + 2)
  11. #define    SIOCX25SFACILITIES    (SIOCPROTOPRIVATE + 3)
  12. #define    SIOCX25GCALLUSERDATA    (SIOCPROTOPRIVATE + 4)
  13. #define    SIOCX25SCALLUSERDATA    (SIOCPROTOPRIVATE + 5)
  14. #define    SIOCX25GCAUSEDIAG    (SIOCPROTOPRIVATE + 6)
  15.  
  16. /*
  17.  *    Values for {get,set}sockopt.
  18.  */
  19. #define    X25_QBITINCL        1
  20.  
  21. /*
  22.  *    X.25 Packet Size values.
  23.  */
  24. #define    X25_PS16        4
  25. #define    X25_PS32        5
  26. #define    X25_PS64        6
  27. #define    X25_PS128        7
  28. #define    X25_PS256        8
  29. #define    X25_PS512        9
  30. #define    X25_PS1024        10
  31. #define    X25_PS2048        11
  32. #define    X25_PS4096        12
  33.  
  34. /*
  35.  * An X.121 address, it is held as ASCII text, null terminated, up to 15
  36.  * digits and a null terminator.
  37.  */
  38. typedef struct {
  39.     char        x25_addr[16];
  40. } x25_address;
  41.  
  42. /*
  43.  *    Linux X.25 Address structure, used for bind, and connect mostly.
  44.  */
  45. struct sockaddr_x25 {
  46.     sa_family_t    sx25_family;        /* Must be AF_X25 */
  47.     x25_address    sx25_addr;        /* X.121 Address */
  48. };
  49.  
  50. /*
  51.  *    DTE/DCE subscription options.
  52.  */
  53. struct x25_subscrip_struct {
  54.     char device[200];
  55.     unsigned int    extended;
  56. };
  57.  
  58. /*
  59.  *    Routing table control structure.
  60.  */
  61. struct x25_route_struct {
  62.     x25_address    address;
  63.     unsigned int    sigdigits;
  64.     char        device[200];
  65. };
  66.  
  67. /*
  68.  *    Facilities structure.
  69.  */
  70. struct x25_facilities {
  71.     unsigned int    winsize_in, winsize_out;
  72.     unsigned int    pacsize_in, pacsize_out;
  73.     unsigned int    throughput;
  74.     unsigned int    reverse;
  75. };
  76.  
  77. /*
  78.  *    Call User Data structure.
  79.  */
  80. struct x25_calluserdata {
  81.     unsigned int    cudlength;
  82.     unsigned char    cuddata[128];
  83. };
  84.  
  85. /*
  86.  *    Call clearing Cause and Diagnostic structure.
  87.  */
  88. struct x25_causediag {
  89.     unsigned char    cause;
  90.     unsigned char    diagnostic;
  91. };
  92.  
  93. #endif
  94.